From 895a5d9e06afce75577c8c4b3c19f9b6ab9e96b3 Mon Sep 17 00:00:00 2001 From: Stevan Earl Date: Wed, 5 Aug 2026 16:37:14 -0700 Subject: [PATCH] fix: corrected trigger wording from follow to event since this applies to AGSCAN and other events not only follows (cherry picked from commit 587e15969264727c4d7a810bff56e364539a6423) --- db/schemas/lib/triggers/create/roles.m4 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/db/schemas/lib/triggers/create/roles.m4 b/db/schemas/lib/triggers/create/roles.m4 index 5f1a6ad..24cdbfa 100644 --- a/db/schemas/lib/triggers/create/roles.m4 +++ b/db/schemas/lib/triggers/create/roles.m4 @@ -131,7 +131,7 @@ CREATE OR REPLACE FUNCTION roles_func () a_type watches.type%TYPE; BEGIN - -- The follow cannot be before the participant's entrydate. + -- The event cannot be before the participant's entrydate. SELECT biography_data.entrydate , watches.animid, watches.date, watches.type INTO a_entrydate @@ -145,7 +145,7 @@ CREATE OR REPLACE FUNCTION roles_func () IF FOUND THEN RAISE EXCEPTION integrity_constraint_violation USING MESSAGE = 'Error on ' || TG_OP || ' of ROLES' - , DETAIL = 'An individual cannot particpate in a follow before' + , DETAIL = 'An individual cannot participate in an event before' || ' their entry to the study' || ' (before BIOGRAPHY_DATA.EntryDate)' || ': Key (PID) = (' @@ -175,7 +175,7 @@ CREATE OR REPLACE FUNCTION roles_func () || ')'; END IF; - -- The follow cannot be after the participant's departdate. + -- The event cannot be after the participant's departdate. SELECT biography_data.departdate , watches.animid, watches.date, watches.type INTO a_departdate @@ -189,7 +189,7 @@ CREATE OR REPLACE FUNCTION roles_func () IF FOUND THEN RAISE EXCEPTION integrity_constraint_violation USING MESSAGE = 'Error on ' || TG_OP || ' of ROLES' - , DETAIL = 'An individual cannot participate in a follow after' + , DETAIL = 'An individual cannot participate in an event after' || ' their departure from the study' || ' (after BIOGRAPHY_DATA.DepartDate)' || ' event with an EVENTS.Behavior of (' -- 2.34.1